package com.an.blog.admin.domain.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.an.common.annotation.ExcelDictFormat;
import com.an.common.convert.ExcelDictConvert;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;


/**
 * 博客文章视图对象 blog_article
 *
 * @author Ann
 * @date 2023-05-08
 */
@Data
@ExcelIgnoreUnannotated
public class BlogArticleVo implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @ExcelProperty(value = "主键")
    private Long articleId;

    /**
     * 分类id
     */
    @ExcelProperty(value = "分类id")
    private Long categoryId;

    /**
     * 分类名称
     */
    @ExcelProperty(value = "分类名称")
    private String categoryName;


    /**
     * 文章标题
     */
    @ExcelProperty(value = "文章标题")
    private String articleTitle;

    /**
     * 文章内容
     */
    @ExcelProperty(value = "文章内容")
    private String articleContent;

    /**
     * 文章图片
     */
    @ExcelProperty(value = "文章图片")
    private Long articleImage;

    /**
     * 文章类型（0原创 1转载 2翻译）
     */
    @ExcelProperty(value = "文章类型", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=原创,1=转载,2=翻译")
    private String articleType;

    /**
     * 原文链接
     */
    @ExcelProperty(value = "原文链接")
    private String originalUrl;

    /**
     * 是否置顶（0否 1是）
     */
    @ExcelProperty(value = "是否置顶", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=否,1=是")
    private String isTop;

    /**
     * 状态（0正常 1停用）
     */
    @ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=正常,1=停用")
    private String status;

    /**
     * 点赞数量
     */
    @ExcelProperty(value = "点赞数量")
    private Long likedCount;

    /**
     * 浏览量
     */
    @ExcelProperty(value = "浏览量")
    private Long viewedCount;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注")
    private String remark;


    /**
     * 创建时间
     */
    @ExcelProperty(value = "发布时间")
    private Date createTime;


    /**
     * 文章标签
     */
    @ExcelProperty(value = "文章标签")
    private Long[] articleTags;

    /**
     * 文章图像url
     */
    @ExcelProperty(value = "文章图片地址")
    private String articleImageUrl;

}
